home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Charlie Rose Science Series Anthology
/
The Charlie Rose Science Series Anthology (Pfizer, Inc.)(2008).iso
/
mac
/
Charlie Rose Science Series Anthology.app
/
Contents
/
Resources
/
movie.swf
/
scripts
/
__Packages
/
hbxFlashTrack2.as
Wrap
Text File
|
2008-02-01
|
7KB
|
246 lines
class hbxFlashTrack2
{
var acct = "DM5407252GFR";
var gn = "pfe.pfizer.com";
var vpc = "HBX0100ft2";
var vjs = "HBX0252.1ft2";
function hbxFlashTrack2()
{
this.req = new LoadVars();
this.reqData = new LoadVars();
this.req.hb = this.acct;
this.req.hec = "-1";
this.req.n = "flash default";
this.req.vcon = "/";
this.req.vpc = this.vpc;
this.req.vjs = this.vjs;
this.req.cd = "1";
this.req.hv = "6";
this.req.ln = System.capabilities.language;
this.req.ss = System.capabilities.screenResolutionX + "*" + System.capabilities.screenResolutionY;
this.req.rf = this.hbGetJSVal("window.document.referrer","bookmark");
this.req.ja = this.hbGetJSVal("window.navigator.javaEnabled()?\'y\':\'n\'");
this.req.sc = this.hbGetJSVal("window.screen.colorDepth",this.hbGetJSVal("window.screen.pixelDepth"));
this.req.pu = this.hbGetJSVal("window.document.URL");
}
function hbSend()
{
this.req.hec = this.req.hec + 1;
this.reqData.hid = new Date().getTime();
for(var _loc2_ in this.req)
{
this.reqData[_loc2_] = this.req[_loc2_];
}
var _loc3_ = this.reqData.toString();
_loc3_ = _loc3_.split("%2E").join(".");
this.reqData.load("http://" + this.gn + "/HG?" + _loc3_);
this.reqData = new LoadVars();
}
function hbSet(varName, varValue)
{
if(this.req[varName] != "" && this.req[varName] != undefined && this.req[varName] != "undefined")
{
this.req[varName] = varValue;
}
else
{
this.reqData[varName] = varValue;
}
}
function hbSetAccount(varValue)
{
this.req.hb = varValue;
}
function hbSetGateway(varValue)
{
this.gn = varValue;
}
function hbSetCustomerId(varValue)
{
this.req.customerid = varValue;
}
function hbSetMulti(obj)
{
trace(">>> HB: SET MULTI: ");
for(var _loc4_ in obj)
{
if(this.req[_loc4_] != "")
{
this.req[_loc4_] = obj[_loc4_];
}
else
{
this.reqData[_loc4_] = obj[_loc4_];
}
}
for(var _loc3_ in this.req)
{
trace(" > " + _loc3_ + ": " + this.req[_loc3_]);
}
}
function hbPageView(pn, mlc)
{
trace(">>> HB: PAGE VIEW: pn: \"" + pn + ", mlc: \"" + mlc + "\"");
this.req.hec = -1;
this.hbSet("n",pn);
this.hbSet("vcon",mlc);
this.hbSend();
}
function hbExitLink(el)
{
this.hbSet("el",el);
this.hbSend();
}
function hbDownload(fn)
{
this.hbSet("fn",fn);
this.hbSend();
}
function hbVisitorSeg(seg)
{
this.hbSet("seg",seg);
this.hbSend();
}
function hbCampaign(cmp)
{
this.hbSet("cmp",cmp);
this.hbSend();
}
function hbFunnel(fnl)
{
this.hbSet("fnl",fnl);
this.hbSend();
}
function hbGoalPage(gp)
{
this.hbSet("gp",gp);
this.hbSend();
}
function hbLink(lid, lpos)
{
this.hbSet("lid",lid);
if(lpos != undefined)
{
this.hbSet("lpos",lpos);
}
this.hbSend();
}
function hbForm(formState, focusField)
{
if(formState == 0)
{
this.hbSet("lf",focusField);
}
else
{
this.hbSet("sf",1);
}
this.hbSend();
}
function hbMediaEvent(mName, mCurPos, mEndPos, mState, mClient, mVersion)
{
var _loc2_ = new Object();
_loc2_["m.f"] = mName;
_loc2_["m.cp"] = mCurPos;
_loc2_["m.ep"] = mEndPos;
_loc2_["m.s"] = mState;
_loc2_["m.cl"] = mClient;
_loc2_["m.cv"] = mVersion;
this.hbSetMulti(_loc2_);
this.hbSend();
}
function hbGetJSVal(val, dval)
{
dval = dval == "null" ? "" : dval;
var _loc1_ = String(flash.external.ExternalInterface.call("eval",val));
if(_loc1_ != undefined && _loc1_ != "null")
{
return _loc1_;
}
return dval;
}
function hbProductView(mCacct, mTz, mPr, mBd, mCa, mPn, mMlc)
{
var _loc2_ = new Object();
_loc2_.epg = "n";
_loc2_.pv = "1";
_loc2_.aid = mCacct;
_loc2_.tz = mTz;
_loc2_.product = mPr;
_loc2_.brand = mBd;
_loc2_.category = mCa;
this.hbSetMulti(_loc2_);
this.hbPageView(mPn,mMlc);
}
function hbAddCart(mCacct, mTz, mPr, mQn, mBd, mCa, mPc, mSr, mPn, mMlc)
{
var _loc2_ = new Object();
_loc2_.epg = "n";
_loc2_.cam = "0";
_loc2_.pv = "0";
_loc2_.abd_type = "cart_add";
_loc2_.aid = mCacct;
_loc2_.tz = mTz;
_loc2_.product = mPr;
_loc2_.quantity = mQn;
_loc2_.brand = mBd;
_loc2_.category = mCa;
_loc2_.price = mPc;
_loc2_.store = mSr;
this.hbSetMulti(_loc2_);
this.hbPageView(mPn,mMlc);
}
function hbCheckOut(mCacct, mTz, mPr, mQn, mBd, mCa, mPc, mSr, mSt, mSh, mCp, mPn, mMlc)
{
var _loc2_ = new Object();
_loc2_.abd_type = "checkout";
_loc2_.aid = mCacct;
_loc2_.tz = mTz;
_loc2_.product = mPr;
_loc2_.quantity = mQn;
_loc2_.brand = mBd;
_loc2_.category = mCa;
_loc2_.price = mPc;
_loc2_.store = mSr;
_loc2_.shippingtype = mSt;
_loc2_.shipping = mSh;
_loc2_.cp = mCp;
this.hbSetMulti(_loc2_);
mPn;
this.hbPageView[mMlc];
}
function hbOrderConfirmation(mCacct, mTz, mPr, mQn, mBr, mCa, mSt, mSh, mPc, mSr, mCp, mOi, mCi, mSc, mSs, mSz, mSco, mPt, mSku, mCu, mDs, mPo, mC1, mC2, mPn, mMlc)
{
var _loc2_ = new Object();
_loc2_.abd_type = "order";
_loc2_.event = "true";
_loc2_.eid = "1";
_loc2_.aid = mCacct;
_loc2_.tz = mTz;
_loc2_.product = mPr;
_loc2_.quantity = mQn;
_loc2_.brand = mBr;
_loc2_.category = mCa;
_loc2_.shippingtype = mSt;
_loc2_.shipping = mSh;
_loc2_.price = mPc;
_loc2_.store = mSr;
_loc2_.cp = mCp;
_loc2_.orderid = mOi;
_loc2_.customerid = mCi;
_loc2_.shipcity = mSc;
_loc2_.shipstate = mSs;
_loc2_.shipzipcode = mSz;
_loc2_.shipcountry = mSco;
_loc2_.paymenttype = mPt;
_loc2_.sku = mSku;
_loc2_.customer_type = mCu;
_loc2_.discount = mDs;
_loc2_.promotion = mPo;
_loc2_.li_custom1 = mC1;
_loc2_.li_custom2 = mC2;
this.hbSetMulti(_loc2_);
this.hbPageView(mPn,mMlc);
}
}